﻿@{
    ViewBag.Title = "Index";
}

<!DOCTYPE html>

<html>
    <head>
        <link href="/Scripts/Plugins/jQUeryUI/jquery-ui-1.8.16.custom.css" rel="stylesheet" type="text/css" />
        <link href="/Scripts/Plugins/ColorPicker/colorpicker.css" rel="stylesheet" type="text/css" />
        <link href="/Scripts/Plugins/Fireworks/fireworks.css" rel="stylesheet" type="text/css" />
        <link href="/Styles/default.css" rel="stylesheet" type="text/css" />
        <title>Hunter vs Alien</title>
    </head>
    <body>
        <div class="gameWrapper">
            <div id="GameControls">
                <div class="hostControls displayNone">
                    <div>
                        <h2>Game Options</h2>
                        Preset GameBoard (1 - 3): <input id="LevelNumber" type="text" value="1" />
                        <input id="GenerateLevelButton" type="button" value="Choose Level" />
                        <br />
                        Fill Factor (0.1 - 0.8): <input id="FillFactor" type="text" value="0.35" />
                        <input id="GenerateBoardButton" type="button" value="Generate Random Board" />
                        <br />
                        Alien Speed (moves per second): <input id="AlienInterval" type="text" value="7" />
                        <br />
                        Hunter Speed (moves per second): <input id="HunterInterval" type="text" value="10" />
                        <br />
                        Bot Speed (moves per second): <input id="BotInterval" type="text" value="6" />
                        <br />
                        AI Alien Bots: <input id="AlienBots" type="text" value="0" />
                        <br />
                        <br />
                        <input id="StartGameButton" type="button" value="StartGame" />
                    </div>
                </div>
                <div class="hostGameInProgressControls displayNone">
                    <input id="RestartGameButton" type="button" value="RestartGame" />
                </div>
                <div class="hostUniversalControls displayNone">
                    <div class="unlocked"></div>
                </div>
            </div>

            <div id="ChatContainer">
                <div id="ChatRoomHeader">
                    <ul id="UserNameHeader" class="visibilityHidden">
                        <li>
                            <div id="MyUserName">
                            </div>
                        </li>
                    </ul>
                </div>

                <div id="ChatRoomUsers">
                    <ul id="ListOfUsers">
                        <li class="noUsersUser">No Active Users</li>
                    </ul>
                </div>
        
                <div id="ChatRoomMessages">
                    <div id="ChatArea"></div>
                    <div id="ChatMessageWrapper">
                        <textarea id="ChatMessage"></textarea>
                    </div>
                </div>
            </div>

            <div id="Login">
                <div class="textAlignCenter">
                    <h1>Login</h1>
                </div>

                <div class="textAlignCenter">
                    <div class="loginOption" id="HunterLogin" data-tokenType="Hunter">
                        @Html.Partial("HunterSvg", new XSocketDemo.Models.Svg(200))
                        <br />
                        <span class="loginOptionCaption">Hunter</span>
                    </div>
                    <div class="loginOption" id="AlienLogin" data-tokenType="Alien">
                        @Html.Partial("AlienSvg", new XSocketDemo.Models.Svg(200))
                        <br />
                        <span class="loginOptionCaption">Alien</span>
                    </div>
                    <div class="clear"></div>
                </div>
            </div>

            <div id="GameBoard" class="displayNone">
                @for (int y = 0; y < 30; y++)
                {
                    for (int x = 0; x < 40; x++)
                    {
                        <div class="boardPiece"></div>
                    }
                    <div class="clear"></div>
                }
            </div>

            <div id="UserNameDialog" class="displayNone">
                UserName: <input id="UserNameTextBox" type="text" />
                <div id="LoginDialogSubContext">
                    <div id="UserTokenWrapper" class="loginDialogPanel">
                    </div>
                    <div class="loginDialogPanel">
                        <p id="ColorPicker"></p>
                    </div>
                </div>
                <div id="LoginErrorMessage">&nbsp;</div>
            </div>

            <div class="clear"></div>
        </div>

        <div id="TestDiv" style="width: 200px; border: 1px solid black; height: 20px;"></div>

        <script type="text/javascript">
            var serverLocation = "@System.Configuration.ConfigurationManager.AppSettings["SocketServerAddress"]";
        </script>
        <script src="/Scripts/Plugins/jQuery/jquery-1.7.2.js" type="text/javascript"></script>
        <script src="/Scripts/Plugins/jQueryUI/jquery-ui-1.8.16.custom.min.js" type="text/javascript"></script>
        <script src="/Scripts/Plugins/Socket.io/socket.io.js" type="text/javascript"></script>
        <script src="/Scripts/Plugins/AutoResize/jquery.autosize-min.js" type="text/javascript"></script>
        <script src="/Scripts/Plugins/ColorPicker/colorpicker.js" type="text/javascript"></script>
        <script src="/Scripts/Plugins/SoundManager/soundmanager2.js" type="text/javascript"></script>
        <script src="/Scripts/Plugins/Fireworks/fireworks.js" type="text/javascript"></script>
        <script type="text/javascript" src="@System.Configuration.ConfigurationManager.AppSettings["SocketServerAddress"]/nowjs/now.js"></script>
        <script src="/Scripts/Game/SoundPlayer.js" type="text/javascript"></script>
        <script src="/Scripts/Game/FireworkMaker.js" type="text/javascript"></script>
        <script src="/Scripts/Game/KeyboardController.js" type="text/javascript"></script>
        <script src="/Scripts/Game/User.js" type="text/javascript"></script>
        <script src="/Scripts/Game/ClientGame.js" type="text/javascript"></script>
        <script src="/Scripts/Home/Index.js" type="text/javascript"></script>
    </body>
</html>